Skip to content
This repository was archived by the owner on Jul 28, 2022. It is now read-only.

feat(plugin): add ios expo plugin#72

Merged
Minishlink merged 7 commits into
bamlab:masterfrom
MaximeCrp:feat/ios-expo-plugin
Jan 25, 2022
Merged

feat(plugin): add ios expo plugin#72
Minishlink merged 7 commits into
bamlab:masterfrom
MaximeCrp:feat/ios-expo-plugin

Conversation

@MaximeCrp
Copy link
Copy Markdown
Contributor

@MaximeCrp MaximeCrp commented Jan 18, 2022

Adding the iOS part of the expo config plugin, to use this module with expo managed workflow.
This plugin adds the Batch API key (iOS and Android Batch keys are usually different) in the Info.plist, as well as starting and registering the RNBatch module at the top of didFinishLaunchingWithOptions in the AppDelegate

@MaximeCrp
Copy link
Copy Markdown
Contributor Author

I'm not testing withReactNativeBatchInfoPlist since it modifies directly the modResults object and not doing any string manipulation on generated Info.plist file

@MaximeCrp
Copy link
Copy Markdown
Contributor Author

MaximeCrp commented Jan 19, 2022

Par rapport à la doc de Batch pour React Native -> iOS, j'ai skippé la partie ajout de l'Apple Team Id (ou DevelopmentTeam) dans le fichier ios/{ProjectName}.xcodeproj/project.pbxproj.
Mon team id est ajouté automatiquement pendant le build (avec expo run:ios).

Comment thread plugin/src/withReactNativeBatchAppDelegate.ts Outdated
Comment thread plugin/src/withReactNativeBatchAppDelegate.ts Outdated
@MaximeCrp MaximeCrp force-pushed the feat/ios-expo-plugin branch from 4c1a36a to 5018b58 Compare January 19, 2022 15:08
@MaximeCrp
Copy link
Copy Markdown
Contributor Author

MaximeCrp commented Jan 19, 2022

@Minishlink Hello ! Des retour à faire sur cette PR ?
Je dois encore ajouter au readme pour la partie iOS

Copy link
Copy Markdown
Contributor

@Minishlink Minishlink left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pas de step pour activer les push dans le projet xcode ? (normalement un fichier entitlements est créé)

Comment thread plugin/src/withReactNativeBatch.ts Outdated
Comment thread plugin/src/withReactNativeBatchAppDelegate.ts
@MaximeCrp
Copy link
Copy Markdown
Contributor Author

MaximeCrp commented Jan 19, 2022

pas de step pour activer les push dans le projet xcode ? (normalement un fichier entitlements est créé)

@Minishlink pour l'ajout da la capability "Push Notifications" elle est déjà activée quand je prebuild sur mon projet. Je suis parti du principe qu'Expo activait toujours celle-ci, un moyen de vérifier ?

@Minishlink
Copy link
Copy Markdown
Contributor

Je n'utilise pas expo mais tu peux faire un nouveau projet expo from scratch en y ajoutant ce plugin. De toute façon ce serait bien de le faire ne serait-ce pour vérifier si votre projet n'a pas déjà des configurations qui ne sont pas "de base".

@MaximeCrp MaximeCrp force-pushed the feat/ios-expo-plugin branch from 719d072 to 33b100a Compare January 20, 2022 08:56
@MaximeCrp MaximeCrp force-pushed the feat/ios-expo-plugin branch from cb9193a to fffb805 Compare January 20, 2022 13:07
@MaximeCrp
Copy link
Copy Markdown
Contributor Author

@JLNPPT @waltoss si vous voulez y jeter un oeil

@MaximeCrp
Copy link
Copy Markdown
Contributor Author

@Minishlink Testé avec un projet expo vide, le plugin fait bien les modifs comme il faut -> permis de voir que je n'importais pas BatchPush au bon endroit dans AppDelegate

Comment thread readme/expo.md Outdated
@Minishlink Minishlink merged commit 10ec82b into bamlab:master Jan 25, 2022
@MaximeCrp MaximeCrp deleted the feat/ios-expo-plugin branch January 26, 2022 20:17
@MaximeCrp
Copy link
Copy Markdown
Contributor Author

Hello @Minishlink
J'avais précisé Expo SDK > 42.0 comme requirement dans le readme avec cette PR
En fait j'ai pu testé un build avec cette version et ça fail à cause d'une incompatibilité de version de Xcode entre react-native-batch-push et expo il me semble. Dans la config de build avec Expo EAS il y a moyen de préciser la version d'xcode, du coup tu sais quelle version est utilisée ici ?

Comme ça je peux updater le readme en précisant qu'il faut utiliser une autre version d'expo (44.0) ou donner la config nécessaire pour les versions 42 et 43

@Minishlink
Copy link
Copy Markdown
Contributor

@MaximeCrp Concernant react-native-batch-push, la seule contrainte de version de XCode serait que la version de XCode supporte iOS 10.
Concernant le SDK Batch, il faut au moins la version 12 de XCode depuis la version 1.18 de Batch.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants